<template>
	<view class="progress">
		<view class="progress-main">
			<u-row>
				<u-col span="4">
					<view class="table-th">套餐名称</view>
				</u-col>
				<u-col span="4">
					<view class="table-th">项目名</view>
				</u-col>
				<u-col span="4">
					<view class="table-th">状态</view>
				</u-col>
			</u-row>
			<view class="tbody">
				<u-row v-for="(item, i) in dataList" :key='i'>
					<u-col span="4">
						<view class="table-tr">{{item.comboName}}</view>
					</u-col>
					<u-col span="4">
						<view class="table-tr">{{item.payItemName}}</view>
					</u-col>
					<u-col span="4">
						<view class="table-tr" style="color: #FBAE70">{{item.statusName}}</view>
					</u-col>
				</u-row>
			</view>
		</view>
		<Load :load="load" />
	</view>
</template>

<script>
	import Load from '@/components/Load/index.vue'
	import { getProgress } from '@/api/physical.js'
	export default {
		components:{ Load },
		data() {
			return {
				load:false,
				comboId:null,
				dataList:[]
			}
		},
		onLoad(op) {
			this.healthNo = op.healthNo||null
			// this.initData()
		},
		methods: {
			initData(){
				this.load = true
				getProgress({healthNo:this.healthNo}).then(data => {
					this.load = false
					let res = data||[]
					res.forEach(item => {
						item.statusName = item.status==='0'?'已检查':'未检查'
					})
					this.dataList = res
				}).catch(e => {
					this.load = false
					this.dataList = []
				})
			},
		}
	}
</script>

<style lang="scss" scoped>
	.progress{
		background-color: #fff;
		height: 100%;
		&-main{
			.table-th{
				height: 90rpx;
				line-height: 90rpx;
				text-align: center;
				font-size: 30rpx;
				font-weight: bold;
			}
			.tbody{
				margin-top: 10rpx;
				max-height: calc(100vh - 90rpx);
				overflow: scroll;
			}
			.table-tr{
				padding: 10rpx 20rpx;
				font-size: 26rpx;
				text-align: center;
			}
		}
	}
</style>
<style>
	.u-col{
		padding: 0 !important;
	}
</style>